@import './code-generator.scss';
body {
  font-family: pingfang SC,helvetica neue,arial,hiragino sans gb,microsoft yahei ui,microsoft yahei,simsun,sans-serif!important;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
/* 表格 */
.el-table {
  width: 100%;
  color: #111;
  th {
      background: #F2F6FC!important;
      color: #111;
  }
}
.drag_table th {
  background: #F2F6FC;
  color: #111;
}
//表格对齐
body .el-table th.gutter {
  display: table-cell !important;
}
body .el-table colgroup.gutter {
  display: table-cell !important;
}

/* 分页 */
.el-pagination {
  float: right;
  margin-top: 10px;
}

/* 对话框 */
.el-dialog {
  display: flex;
  flex-direction: column;
  margin: 0!important;
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  max-height: calc(100%);
}
.el-dialog .el-dialog__body {
  flex: 1;
  overflow: auto;
}
.dialog-header {
  width: 100%;
  font-weight: bold;
  padding-bottom: 8px;
  border-bottom: solid 1px #eee;
}
.el-dialog__body {
  padding-top: 7px;
  padding-bottom: 7px;
  margin-top: 7px;
  margin-bottom: 7px;
}
.el-popover {
  max-height: calc(100% - 40px);
  overflow-y: auto;
}

/* Container 布局容器 */
.el-container {
  .el-main {
    padding-top: 5px;
    padding: 0px }
}

/* 主页面搜索框 */
.search-row {
  // padding-bottom: 5px;
  .el-col {
    max-height: 46px;
  }
  .el-form-item__label {
    text-align-last: justify;
    -moz-text-align-last: justify;
  }
  .el-form-item {

  }
  .el-select {
    width: 100%!important;
  }
  .el-input,  .el-input__inner, .el-date-editor {
    width: 90%!important;
  }
  .el-input__suffix, .el-cascader .el-input__suffix{
    right: 12%;
  }
  .form-input-number {
    width: 100%;
    .form-input-number-inner {}
    .suffix {}
  }
}
.form-input-number {
  display: flex;
  justify-content: center;
  align-content: center;
  box-sizing: border-box;
  .form-input-number-inner {
    flex: 1;
  }
  .suffix {
    width: 30px;
    display: inline-block;
    text-align: center;
    font-size: 12px;
  }
}

/* 编辑form */
.edit-form {
  .el-date-editor.el-input { width: 100%; }

  .el-select { width: 100%;  }
}

.el-input.is-disabled .el-input__inner, .el-textarea.is-disabled .el-textarea__inner {
  color: #606266!important;
}

/* 编辑框中 计数器的InputNumber的文本左对齐，宽度100% */
.el-input-number {
  width: 100% !important;
  .el-input__inner {
        text-align: left;
  }
}
.el-input-number--small { width: 100%; }


.el-cascader { width:100%; }


/* disable控件的样式 */
.el-switch.is-disabled {
  opacity: 1
}
.el-input.is-disabled .el-input__inner {
  background-color: #FFF;
  color: #606266;
}
.el-textarea.is-disabled .el-textarea__inner {
    background-color: #FFF;
    color: #606266;
}

/* 查询条件 */
.query-form-container {
  background: #fff;
  padding: 20px 0px 10px 0px;
  border-bottom: 0;
  /*box-shadow: 0px 0px 4px rgba(0,0,0,.1);*/
  .query-form {
    margin-bottom: 18px;
  }
  .el-main, .el-aside {
    overflow: hidden!important;
  }
}

// 新增
.page-container {
  padding: 18px;
  background: #fff;
  flex: 1;
  min-width: 0;
  .page-container-header {
    display: flex;
    justify-content: space-between;
  }
  .page-container-header-end {
    display: flex;
    justify-content: end;
    margin-bottom: 10px;
  }
  .el-tabs__header {
    margin: 0;
  }
  .el-tabs--card > .el-tabs__header {
    border-bottom: 0;
  }
}

.page-left-container, .page-right-container {
  padding: 18px;
  background: #fff;
  box-sizing: border-box;
}

.page-left-container {
  flex: 0 0 240px;
  border-right: 1px solid #f5f5f5;
}
.page-left-container .tree-title {
  font-size: 14px;
  display: inline-block;
  padding: 10px 0;
}
.page-left-container .el-aside {
  width: 100% !important;
  .el-table__body-wrapper {
    cursor: pointer;
  }
}
.page-left-container .el-table:before {
  height: 0!important;
}
.page-right-container {
  flex: 1;
  min-width: 0;
}

/* 数据展示 */
.data-container {
  padding: 18px;
  background: #fff;
  margin-bottom: 10px;
  /*box-shadow: 0px 0px 4px rgba(0,0,0,.1);*/
  .el-table th {
    background-color: #f8f8f9;
  }
}

.tab-item {
  position: relative;
  .tab-option {
    position: absolute;
    top: -46px;
    right: 0;
  }
}
.data-tabs {
  background-color: #fff;
  padding: 0 18px
}
.wf-tabs {
  .el-tabs__nav {
    float: left;
  }

}
.wf-cards {
  .image {
    width: 100%;
    height: 200px;
    background-color: #f5f5f5;
    text-align: center;
    .el-image__inner {
      width: 80%;
    }
  }
  .wf-cards-name {
    font-size: 14px;
  }
  .bottom {
    display: flex;
    justify-content: center;
  }
}
.mask-layout {
  position: absolute;
  width: calc(100% - 200px);
  height: calc(100% - 36px);
  z-index: 100;
  -webkit-transition: 0.3s width ease-in-out;
  transition: 0.3s width ease-in-out;
  &.is-collapse {
    width: calc(100% - 64px);
  }
}
.mask-dialog-layout {
  position: absolute;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  z-index: 100;
}

.el-loading-spinner {
  background-image: url("~@/assets/images/loading2.gif");
  background-repeat: no-repeat;
  background-size: 40px;
  margin-top: -50px!important;
  width: 100%;
  height: 100px;
  background-position: center;
  top: 50%;
}
.el-loading-spinner .circular {
  display: none;
}

.el-loading-spinner .el-loading-text {
  margin: 85px 0px;
}

// 用于解决表格最右横线问题
.el-table__fixed-right{
  height: 100% !important;
}
 .el-table__fixed {
  height: 100% !important;
}
.code-desinge-dialog {
  .el-dialog, .el-dialog__body {
    overflow: hidden!important;
  }
  .el-dialog__header {
    padding: 5px 10px;
    display: flex;
    align-items: center;
    .dialog-header {
      text-align: right;
    }
  }
  .el-dialog__body {
    padding: 0;
    margin: 0;
  }
  // 设计器
  .code-generator-container {
    height: 100%;
    .center-board-row {
      .el-dialog {
        left: 0;
        transform: translate(0, 0);
        margin: 0 auto!important;
      }
    }

    .popover-item-container .el-popover {
      max-height:none;
    }
  }
}
// 编辑表格修改图标隐藏
.dc-ux-grid_EditTable {
  .elx-cell--edit-icon {
    display: none;
  }
}

.template-card {
  position: relative;
  cursor: pointer;
  box-sizing: border-box;
  &:hover {
    .card-select {
      visibility: visible;
      transition: all .4s;
      .el-button {
        margin-top: 110px;
      }
    }
    &.card-selected {
      border: 1px solid $--color-primary!important;
      outline: 1px solid $--color-primary!important;
      box-shadow: 0 0 2px 4px rgba($color: $--color-primary, $alpha: 0.1)!important;
    }
  }
  &.card-selected {
    border: 1px solid $--color-primary;
    outline: 1px solid $--color-primary!important;
    box-shadow: 0 0 2px 4px rgba($color: $--color-primary, $alpha: 0.1);
    .card-select {
      visibility: visible;
    }
    .el-result {
      height: 100%;
      svg {
        width: 44px;
        height: 44px;
      }
      .el-result__title {
        margin-top: 0;
        p {
          font-size: 14px;
        }
      }
    }
    .selected-flag {
      width: 0;/*1.设置宽高为0*/
      height: 0;
      top: 0;
      right: 0;
      position: absolute;
      border-left: 40px solid transparent;
      border-top: 40px solid $--color-primary;
      i {
        position: absolute;
        color: #fff;
        top: -37px;
        right: 2px;
        font-size: 20px;
      }
    }
  }
  .el-card__body {
    padding: 0!important;
  }
  .el-image {
    width: 100%;
    height: 200px;
    display: block;
    .error-image {
      height: 100%;
      display: flex;
      justify-content: center;
      align-items: center;
      i {
        font-size: 50px;
        color: #ccc;
      }
    }
  }
  .card-title, .card-detail {
    font-size: 12px;
    padding: 2px 10px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }
  .card-detail {
    color: #999;
    display: flex;
    justify-content: space-between;
    align-items: center;
    p {
      flex: 1;
      margin: 0;
      padding: 0;
      overflow: hidden;
      text-overflow: ellipsis;
      white-space: nowrap;
    }
    .el-button {
    }
  }
  .card-select {
    visibility: hidden;
    position: absolute;
    z-index: 10;
    height: 200px;
    top: 0;
    left: 0;
    right: 0;
    background: rgba(255,255,255,0);
    transition: all .4s;
    text-align: center;
    .el-button {
      transition: all .4s;
      margin-top: 120px;
    }
  }
}

// 新版样式
.main {

}
.fix-main-content {
  box-shadow: 0 0 6px rgba(0,0,0, 0.1);
  background-color: #fff;
  border-radius: 6px;
  > .el-row.dc-container {
    padding: 20px;
    .el-dialog__header {
      .el-dialog__title {
        font-size: 14px;
        font-weight: bold;
      }
    }
    .plTableBox {
      .elx-table {
        .elx-table--header-wrapper {
          .elx-table--header {
            background-color: #F2F6FC;
          }
        }
      }
    }
    > .el-form {
      padding: 10px 0;
      border-top: 1px solid #e8eaec;
    }
    > .el-row + .plTableBox {
      margin-top: 10px;
    }
    > .el-container {
      margin: -10px;
      .el-header, .el-aside, .el-main {
        margin: 10px;
        padding: 0;
      }
      .el-aside {
        > .el-row {
          .elx-table {
            .elx-table--border-line {
              border: none;
            }
          }
        }
        .elx-table.border--full .elx-body--column, .elx-table.border--full .elx-footer--column, .elx-table.border--full .elx-header--column {
          background-image: none;
        }
      }
      .el-main {
        > .el-row {
          > .el-row + .plTableBox {
            margin-top: 10px;
          }
          > .el-form {
            padding: 10px 0;
            border-top: 1px solid #e8eaec;
          }
        }
      }
    }
    .el-tabs {
      height: 100%;
      display: flex;
      flex-direction: column;
      .el-tabs__content {
        height: 100%;
        overflow-y: auto;
      }
    }
  }
}


/* 控制编辑表格表单校验显示异常 */
.dc-el-form_ElEditForm .dc-ux-grid_EditTable {
  .el-form-item {
    margin-bottom: 0;
    .el-form-item__error {
      top: auto;
      bottom: 0;
    }
  }
  .elx-tree-cell {
    display: flex;
  }
  .my-input-sc {
    display: flex;
    align-items: end;
    height: auto!important;
    line-height: normal!important;
    .el-form-item__content {
      position: static;
    }
    .el-form-item__error {
      left: 0;
    }
    &.my-input-disabled {
      background-color: #F5F7FA;
      border-color: #E4E7ED;
      color: #606266;
      cursor: not-allowed;
    }
    &.my-input-readonly {
      background-color: #F5F7FA;
      border-color: #E4E7ED;
      color: #606266
    }
    .el-form-item--default {
      height: 40px;
      line-height: 40px;
    }
    .el-form-item--medium {
      height: 36px;
      line-height: 36px;
    }
    .el-form-item--small {
      height: 32px;
      line-height: 32px;
    }
    .el-form-item--mini {
      height: 28px;
      line-height: 28px;
    }
  }
}
